Skip to content

Report what the lifecycle observer saw, and drive focus in the probe - #28

Merged
bytetroll merged 1 commit into
masterfrom
appkit-input-and-diagnostics
Nov 9, 2026
Merged

bytetroll merged 1 commit into
masterfrom
appkit-input-and-diagnostics

Conversation

@bytetroll

Copy link
Copy Markdown
Contributor

Two findings from the macOS runs, neither guessed at.

The in-process input probe showed active=0 key=0 responder=NSTextView with text=1 and the entry holding a space. Typing therefore reaches the focused field and becomes a provider event, but Tab did not move focus and was inserted as text instead: the key-view loop is AppKit's and wants an active application, which a hosted runner does not give an accessory app. Tab navigation is not provider behaviour, so the probe now moves focus through the provider and sends space to each control, which is what actually has to work -- real input reaching a control and becoming an event. The reported active and key state stays, because it is what explained the first result.

The lifecycle failure survived giving the run loop a turn, so rather than guess again the observer now says what it saw. A mismatch reports the baseline, how many windows AppKit still lists, and how many of those are visible, which separates "closed but still listed" from "never released at all". The counts cost nothing on the platforms that already pass and change no assertion, so the fixture still reports the 235 checks the display contract requires.

Two findings from the macOS runs, neither guessed at.

The in-process input probe showed `active=0 key=0 responder=NSTextView`
with `text=1` and the entry holding a space. Typing therefore reaches
the focused field and becomes a provider event, but Tab did not move
focus and was inserted as text instead: the key-view loop is AppKit's
and wants an active application, which a hosted runner does not give an
accessory app. Tab navigation is not provider behaviour, so the probe
now moves focus through the provider and sends space to each control,
which is what actually has to work -- real input reaching a control and
becoming an event. The reported active and key state stays, because it
is what explained the first result.

The lifecycle failure survived giving the run loop a turn, so rather
than guess again the observer now says what it saw. A mismatch reports
the baseline, how many windows AppKit still lists, and how many of
those are visible, which separates "closed but still listed" from
"never released at all". The counts cost nothing on the platforms that
already pass and change no assertion, so the fixture still reports the
235 checks the display contract requires.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@bytetroll
bytetroll merged commit 263cbf0 into master Nov 9, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant